#pragma once
#include <list>
class LRU_Stack
{
public:
	LRU_Stack(void);
	LRU_Stack(int pw, int rep, int size);
	~LRU_Stack(void);

	int cache_size;
	int m_power_aware_mode;  
	// 0; off
	// 1: on

	int m_cache_replace_mode;
	//0:LRU
	//1:MRU
	
	std::list<int> m_cahce_regular;
	std::list<int> m_cahce_priority;

	int accessBlock(int block_addr, int mode); 
	//return the block addr if cache miss, otherwise return -1
	//mode: regular/priority
	bool findBloack(int block_adde, int mode);
	void updateBloack(int block_adde, int mode);
};

